import java.util.Arrays;
import java.util.List;
import java.util.stream.Collectors;

public class demo {
    public static void main(String[] args) {
        User user = new User();
        user.setName("111");
        List<String> strings = Arrays.asList("A", "B", "B", "C", "D", "D", "E");
        strings.stream().distinct().forEach(System.out::println);
//        System.out.println(strings.stream().filter(User::getName));
    }
}

class User{
    private int id;
    private String name ;

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public  String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }


}
